import type { RouteRecordWithMenuItem } from "@/router/types";

import BasicLayout from "@/layouts/BasicLayout";

import Search from "@/views/list/search";
import BasicList from "@/views/list/basic-list";
import CardList from "@/views/list/card-list";

import Articles from "@/views/list/search/articles";
import Projects from "@/views/list/search/projects";

export default {
  path: "/list",
  key: "/list",
  label: "列表页",
  sort: 8,
  element: <BasicLayout />,
  children: [
    {
      path: "search",
      key: "/list/search",
      label: "搜索列表",
      element: <Search />,
      children: [
        {
          path: "articles",
          key: "/list/search/articles",
          label: "搜索列表-文章",
          element: <Articles />,
        },
        {
          path: "projects",
          key: "/list/search/projects",
          label: "搜索列表-项目",
          element: <Projects />,
        },
      ],
    },
    {
      path: "basic-list",
      key: "/list/basic-list",
      label: "标准列表",
      element: <BasicList />,
    },
    {
      path: "card-list",
      key: "/list/card-list",
      label: "卡片列表",
      element: <CardList />,
    },
  ],
} as RouteRecordWithMenuItem;
